The disclosed embodiments of the present invention relate to image compression, and more particularly, to a method and apparatus for performing lossy image compression through source quantization (which is bypassed in lossless image compression) and a lossless compression kernel (which is also used in lossless image compression), and related method and apparatus for image decompression.
An image compression operation may employ either a lossless compression algorithm or a lossy compression algorithm. When the lossless compression algorithm is used by a transmitting end to encode source pixel data into encoded bit-stream data, the reconstructed pixel data derived from decoding the encoded bit-stream data at a receiving end should be identical to the source pixel data. When the lossy compression algorithm is used by a transmitting end to encode source pixel data into encoded bit-stream data, the reconstructed pixel data derived from decoding the encoded bit-stream data at a receiving end may not be identical to the source pixel data. With regard to the lossy compression, several functions may involve lossy operations. For example, the transformation stage, entropy coding stage and residue quantization stage may be implemented using lossy operations.
If the transmitting end is required to support both of lossless compression and lossy compression for a particular application, one conventional design of the transmitting end may have one image compressor dedicated to performing the lossless compression and another image compressor dedicated to performing the lossy compression. However, such an image compression design is not cost-effective.